{% extends "base.html" %}

{% block title %}e投资官网-首页{% endblock %}

{% block head %}
<link rel="stylesheet" href="{{ url_for('static',filename='css/index.css') }}">

    <script type="text/javascript" src="{{ url_for('static',filename='js/love.js') }}"></script>　
{% endblock %}

{% block body %}

            <form class="form-inline my-2 my-lg-0" method="GET" action="{{ url_for('qa.search') }}" style="
        width:1200px;
        margin-left:30px;">
      <input class="form-control mr-sm-2" type="search" placeholder="关键字" aria-label="Search" name="q" style="
        width:726px;
        height:44px;
        margin-left: 160px">
      <button class="btn btn-outline-success my-2 my-sm-0" type="submit" style="
    height:44px;">搜索</button>
    </form>
       　
<div class="row" style="margin-top:0px;">
<div class="col"></div>
<div class="col-8">
    <ul class="question-ul">
        {% for question in questions %}
            <li>
            <div class="side-question">
                <img class="side-question-avatar" src="{{ url_for('static',filename='images/avatar.jpg') }}" alt="" >
            </div>
            <div class="question-main">
                <div class="question-title"><a href="{{ url_for('qa.question_detail',question_id=question.id) }}">{{ question.title }}</a></div>
                <div class="question-content">{{ question.content }}</div>
                <div class="question-detail">
                    <span class="question-author">{{ question.author.username }}</span>
                    <span class="question-time">{{ question.create_time }}</span>
                </div>
            </div>
        </li>
        {% endfor %}

    </ul>
</div>

<div class="col"></div>
</div>
{% endblock %}